package com.banach.prema.repository.dataobject;

import com.baomidou.mybatisplus.annotation.TableName;

import java.util.Date;

/**
 * @author ajun
 * 
 */
@TableName("bnh_group_msg")
public class GroupMsgDO {
	private String id;
	private Integer msgSeq;//消息序列号，一条消息的唯一标示
	private String groupId;//产生群消息的群组 ID
	private String type;//产生群消息的 群组形态介绍，例如 Private，Public 和 ChatRoom
	private Date msgTime;//消息发送的时间戳，对应后台 Server 时间
	private String from_account;//消息发送者 Identifier
	private String operator_account;//请求发起者 Identifier，可以用来识别是否为管理员请求的
	private Long random;//发消息请求中的 11 位随机数
	private String msgBody;//息体，具体参见
	
	private Boolean recall;//是否已经撤回
	
	public String getGroupId() {
		return groupId;
	}
	public void setGroupId(String groupId) {
		this.groupId = groupId;
	}
	public String getType() {
		return type;
	}
	public void setType(String type) {
		this.type = type;
	}
	public String getFrom_account() {
		return from_account;
	}
	public void setFrom_account(String from_account) {
		this.from_account = from_account;
	}
	public String getOperator_account() {
		return operator_account;
	}
	public void setOperator_account(String operator_account) {
		this.operator_account = operator_account;
	}
	public String getMsgBody() {
		return msgBody;
	}
	public void setMsgBody(String msgBody) {
		this.msgBody = msgBody;
	}
	public Integer getMsgSeq() {
		return msgSeq;
	}
	public void setMsgSeq(Integer msgSeq) {
		this.msgSeq = msgSeq;
	}
	public Date getMsgTime() {
		return msgTime;
	}
	public void setMsgTime(Long msgTime) {
		this.msgTime = new Date(((long)msgTime)*1000);
	}
	public String getId() {
		return id;
	}
	public void setId(String id) {
		this.id = id;
	}
	public Boolean getRecall() {
		return recall;
	}
	public void setRecall(Boolean recall) {
		this.recall = recall;
	}

	public GroupMsgDO setMsgTime(Date msgTime) {
		this.msgTime = msgTime;
		return this;
	}

	public Long getRandom() {
		return random;
	}

	public GroupMsgDO setRandom(Long random) {
		this.random = random;
		return this;
	}
}
